using System;

namespace Qplus.protocol
{
    public class ERROR_PACKET : InPacket{
	    /**
	     * 超时
	     */
	    public const int ERROR_TIME_OUT = 0x0;
	
	    /**
	     * 连接异常断开
	     */
	    public const int ERROR_CONNECT_EXCEPTION = 0x1;
	
	    /**
	     * 未知包
	     */
	    public const int ERROR_UNKNOWN_PACKET = 0x2;

	    private int errorCode;
	
	    public ERROR_PACKET(int error){
		    //setListenerKey(MessageID.ERROR_PACKET);
		    this.errorCode = error;
	    }
	
	    //public ERROR_PACKET(){
		//    setListenerKey(MessageID.ERROR_PACKET);
	   // }
	
	    
	    protected override void parseBody(byte[] data, int offset, int count) {
	    }

	    public int getErrorCode() {
		    return errorCode;
	    }

	    public void setErrorCode(int errorCode) {
		    this.errorCode = errorCode;
	    }
	
	    
	    public  byte[] getData() {
		    return new byte[0];
	    }
    }
}
